12/4/2019 6:00:00 AM
In this post, I explain the outbox pattern and implement an example in C#. The outbox pattern can be used when one business transaction needs to happen as a result of another business transaction but it's not possible to combine them into the same database transaction. The example contains two applications. The first allows a user to add titles and authors of books. After a new book is added, a row is created in the outbox. The second application processes the entries in the outbox. The example requires .NET Core 2.1 and SQL Server 2017 express.